from pages.course_page import CoursePage


class CourseOper:
    def __init__(self, driver):
        self.page = CoursePage(driver)

    def click_course_exam(self):
        self.page.find_course_exam().click()

    def click_clicking_to_exam(self):
        self.page.find_clicking_to_exam().click()

    def click_exam_record(self):
        self.page.find_exam_record().click()

    def get_credit_value_status(self):
        try:
            status = self.page.find_credit_value_status().text
        except Exception as e:
            status = ''
        return status
